home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1996 February: Tool Chest / Apple Developer CD Series Tool Chest February 1996 (Apple Computer)(1996).iso / Tool Chest / Development Tools & Languages / Macintosh Common Lisp Related / User Contributions / zebu v3.3.3 (LALR parser) / test / pc1-printers.lisp < prev    next >
Encoding:
Text File  |  1994-09-12  |  1.9 KB  |  65 lines  |  [TEXT/ttxt]

  1. ; -*- mode:     CL -*- ----------------------------------------------------- ;
  2. ; File:         pc1-printers.l
  3. ; Description:  
  4. ; Author:       Joachim H. Laubsch
  5. ; Created:      13-Apr-92
  6. ; Modified:     Tue Apr 27 09:54:57 1993 (Joachim H. Laubsch)
  7. ; Language:     CL
  8. ; Package:      CL-USER
  9. ; Status:       Experimental (Do Not Distribute) 
  10. ; RCS $Header: $
  11. ;
  12. ; (c) Copyright 1992, Hewlett-Packard Company
  13. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  14. ; Revisions:
  15. ; RCS $Log: $
  16. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  17. (in-package "CL-USER")
  18.  
  19. (defun PRINT-PROPOSITIONAL-VARIABLE (ITEM STREAM LEVEL)
  20.   (DECLARE (IGNORE LEVEL))
  21.   (format STREAM
  22.       "~S"
  23.       (PROPOSITIONAL-VARIABLE--name ITEM)))
  24.  
  25. (defun PRINT-BOOLEAN-OR (ITEM STREAM LEVEL)
  26.   (DECLARE (IGNORE LEVEL))
  27.   (format STREAM
  28.       "~S or ~S"
  29.       (BOOLEAN-EXPR--RAND1 ITEM)
  30.       (BOOLEAN-EXPR--RAND2 ITEM)))
  31.  
  32. (defun PRINT-BOOLEAN-AND (ITEM STREAM LEVEL)
  33.   (DECLARE (IGNORE LEVEL))
  34.   (format STREAM
  35.       "~S and ~S"
  36.       (BOOLEAN-EXPR--RAND1 ITEM)
  37.       (BOOLEAN-EXPR--RAND2 ITEM)))
  38.  
  39. (defun print-atomic-wff (item stream level)
  40.   (declare (ignore level))
  41.   (format stream
  42.       "~a(~a)"
  43.       (atomic-wff--predicate item)
  44.       (atomic-wff--role-argument-pairs item)))
  45.  
  46. (defun print-rap-list (item stream level)
  47.   (declare (ignore level))
  48.   (if (rap-empty-list-p (rap-list--rest item))
  49.       (format stream "~a" (rap-list--first item))
  50.     (format stream
  51.         "~a ~a"
  52.         (rap-list--first item)
  53.         (rap-list--rest item))))
  54.  
  55. (defun print-role-argument-pair (item stream level)
  56.   (declare (ignore level))
  57.   (format stream
  58.       "~a: ~a"
  59.       (role-argument-pair--role item)
  60.       (role-argument-pair--argument item)))
  61.  
  62. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  63. ;;                            end of pc1-printers.l
  64. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
  65.